package com.example.springbootdemo.job;

import lombok.extern.slf4j.Slf4j;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

@Slf4j
@Component
public class ScheduleTask {

    //@Scheduled(cron="0 0 0 * * ?")
    @Scheduled(fixedRate = 24*60* 60 * 1000)
    private void doDistribution() {
        log.info("-------- execute distribution task --------");
        log.info("-------- 系统自带的定时任务--------");
        log.info("-------- end distribution task --------");
    }
}
